package com.hex.ds.hdtp.core.app.data.contrast.service;

import com.hex.ds.hdtp.core.app.common.service.IBasicService;
import com.hex.ds.hdtp.core.app.data.contrast.dto.request.CrossDbContrastTaskRequestDto;
import com.hex.ds.hdtp.core.app.data.contrast.dto.response.CrossDbContrastListResponseDto;
import com.hex.ds.hdtp.core.app.data.contrast.dto.response.CrossDbContrastTemplateResponseDto;
import com.hex.ds.hdtp.core.inf.data.contrast.po.CrossDbContrastTaskPo;
import org.springframework.core.io.ByteArrayResource;
import org.springframework.web.multipart.MultipartFile;

import java.util.HashMap;
import java.util.List;

/**
 * @Package: com.hex.ds.hdtp.core.app.data.contrast.service
 * @ClassName ICrossDbContrastTaskService
 * @Description: 跨库比对任务-业务接口
 * @Author: wz.li
 * @Date 2023/7/24 17:13
 * @Version v2.0.2
 **/
public interface ICrossDbContrastTaskService extends IBasicService<CrossDbContrastTaskRequestDto> {

    /*
     * @Method: batchRemoveById <br>
     * @Param: [pkIds] <br>
     * @Return: void <br>
     * @Description：跨库对比任务-批量删除<br>
     * @Author： wz.li<br>
     * @Date： 2023/7/24 18:03 <br>
     * @Version： V2.0.2<br>
     */
    void batchRemoveById(List<String> pkIds);

    /**
     * 批量对比
     *
     * @param dataRange
     * @param pkIds
     */
    void contrast(String dataRange, List<String> pkIds);

    /**
     * @Method addWithBackId
     * @Param
     * @param crossDbContrastTaskRequestDto
     * @Return java.lang.String
     * @Description 新增并返回主键
     * @Author Wang zhihao
     * @Date 2023/8/16 17:38
     * @Version V1.0
     */
    String addWithBackId(CrossDbContrastTaskRequestDto crossDbContrastTaskRequestDto);

    void doContrast(CrossDbContrastTemplateResponseDto contrastTemplate, String pkId, List<CrossDbContrastListResponseDto> contrastLists, CrossDbContrastTaskPo contrastTask);

    HashMap<String,Object> importContrast(MultipartFile file);

    ByteArrayResource export(List<String> pkIds);
}
